﻿<%@ Control Language="C#" Inherits="System.Web.Mvc.ViewUserControl<dynamic>" %>

<% WebApp.Models.Person person = (WebApp.Models.Person) ViewData["ProfileModel"]; %>
<div class="accountControl">
<% if (person != null)
    {
%>
        <a href="<%= Url.Action("Index", "Profile") %>"><%=person.Name%></a>
        <!-- Redirect to logout page in the callback function -->
        <a onclick="FB.logout(loggedOut); return false;">Logout</a>
<% 
    }
    else
    { 
        %>
        <!-- // TODO: Add something here? -->
        &nbsp;
        <%
    } 
%>
</div>